import request from '@/utils/request'

// 查询配方管理列表
export function list(query) {
    return request({
      url: '/api/law_inci/list',
      method: 'get',
      params: query
    })
  }

export function all_inci(query) {
  return request({
    url: '/api/all_inci/list',
    method: 'get',
    params: query
  })
}

export function law_incibyId(id) {
  return request({
    url: '/api/law_inci?id='+id,
    method: 'get',
  })
}

// 新增原料信息管理
export function add(data) {
    return request({
      url: '/api/law_inci',
      method: 'post',
      data: data
    })
  }

// 修改原料信息管理
export function edit(data) {
    return request({
      url: '/api/law_inci',
      method: 'put',
      data: data
    })
  }

// 删除原料信息管理
export function del(data) {
    return request({
      url: '/api/law_inci',
      method: 'delete',
      data: data
    })
  }

  //根据INCI查询RM FM
  export function queryAllByRmAndPro(query) {
    return request({
      url: '/api/law_inci/queryAllByRmAndPro',
      method: 'get',
      params: query
    })
  }
